/* 放置一些各个页面可能用到的公共样式 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 导航栏样式 */
.nav {
    height: 50px;
    background-color: rgba(51, 51, 51, 0.4);
    color: white;
    display: flex;
    /* 垂直居中 */
    align-items: center;
}

/* 头像圆形 */
.nav img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin-left: 30px;
    margin-right: 10px;
}

.nav .spacer {
    width: 70%;
}

.nav a {
    color: white;
    text-decoration: none; /* 去掉下划线 */
    padding: 0 10px;
}

/* 设置背景 */
html, body {
    height: 100%;
}

body {
    background: url("../image/background.jpg") no-repeat center center;
    background-size: cover;
}

/* 版心相关的样式 */
.container {
    width: 1000px;
    height: calc(100% - 50px);
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
}

.container .left {
    height: 100%;
    width: 200px;
}

.container .right {
    height: 100%;
    width: 795px;
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    overflow: auto;
}

/* card相关的样式 */
.card {
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    padding: 30px;
}

.card img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
}

.card h3 {
    text-align: center;
    padding: 10px;
}

.card a {
    /* a 默认是行内元素，行内元素很多边距不生效，简便起见，直接用块级元素去处理 */
    display: block;
    text-align: center;
    color: #999;
    padding: 10px;
    text-decoration: none;
}

.card .counter {
    display: flex;
    justify-content: space-around;
    padding: 5px;
}